﻿using System;
using System.Collections.Generic;
using System.Text;

namespace Comun
{
    class Select:QueryBuilder
    {
        public override String build()
        {
            StringBuilder query = new StringBuilder();
            query.Append(SELECT);
            query.Append(this.noEsNulo(this.campos) ? this.campos : "*");
            query.Append(FROM).Append(this.tabla);
            if(this.noEsNulo(this.condicion)){
                query.Append(WHERE).Append(this.condicion);
            }
            return query.ToString();
        }
    }
}
